package com.jftone.bh.app.config;

import com.jftone.bh.app.data.AreaInfoQry;
import org.apache.log4j.Logger;
import org.jftone.component.BeanContext;
import org.jftone.config.AppListener;
import org.jftone.data.memcache.MemcacheTemplate;
import org.jftone.data.redis.RedisTemplate;

public class CommonLoad implements AppListener {
	private Logger logger = Logger.getLogger(CommonLoad.class);
	
	
	public void load() {
		try {
			//AreaInfoQry.createCache();
		} catch (Exception e) {
			logger.error("加载初始化数据错误", e);
		}
	}

	public void destroy() {
		try {
			BeanContext.getBean(RedisTemplate.class).shutdown();
		} catch (Exception e) {
			logger.error("注销业务数据错误", e);
		}
	}
}
